from flask import (Blueprint, request, session)
from flaskr.server.LoadServer import *

bp = Blueprint('delSheet',__name__, url_prefix='/delSheet')

loadServer = LoadServer(session)

@bp.route('', methods = ['POST'])
def delSheet():
    sheet_name = request.json.get('sheetName')

    if loadServer.del_load(sheet_name):
        return{
            'code': 200,
            'msg': '删除成功',
        }

    else:
        return{
            'code': 500,
            'msg': '删除失败',
        }

